﻿using KINLO.DRV.Drv;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace KINLO.DRV.Machine
{
    /// <summary>
    /// honeywell 3310g
    /// </summary>
    public class HWScannerMachine
    {
        #region 字段
        private static readonly log4net.ILog log = log4net.LogManager.GetLogger(typeof(KNCScannerMachine));
        HWScannerDrv Scanner;
        string IP;
        int Port;
        public string ID;

        System.Timers.Timer timer;
        #endregion

        #region 方法
        public HWScannerMachine(string ip, int port, string id, int timeout = 1000)
        {
            IP = ip;
            Port = port;
            ID = id;
            Scanner = new HWScannerDrv(ip, port, id, timeout);
        }
        public bool Connected
        {
            get { return Scanner.Connected; }
        }
        public void StartScan()
        {
            Scanner.StartScan();
        }
        public string Receive()
        {
            return Scanner.Receive();
        }
        public void StopScan()
        {
            Scanner.StopScan();
        }
        public void Open()
        {
            Scanner.Open();
        }
        #endregion
    }
}
